<?php
// Load Header
$this->set("title_for_layout", __("Tin tức - Sự kiện", true));
?>
<?php echo $html->css('/news/css/page/page');?>
<div id="maincontentwrap">
	<div id="contentinner" id="main">
		<h2 class="articles"><?php __('Tin tức - Sự kiện');?></h2>
		<div class="wd-right-content">
			<div class="wd-wd-section">
				<?php echo $this->element("projects", array('plugin'=>'projects')); ?>
			</div>
		</div>
		<div class="wd-main-content">
			<div class="wd-section">
			<?php 
				foreach($categories as $category)
				{  
			?>
					<?php if(isset($category['top_news']) && $category['top_news'] != null){?>
					<h3 class="articles"><a href="<?php echo $html->url('/news/news/listnews/'). $category['NewsCategory']['alias']?>"><?php echo $category['NewsCategory']['name'];?></a></h3>
						<ul class="wd-news-entries">
						<?php foreach($category['top_news'] as $article){ ?>
							<li>
								<h4><a href="<?php echo $html->url('/news/news/view/'). $article['News']['alias'] .'/'. $category['NewsCategory']['alias']?>"><?php echo $article['News']['title'] ?></a></h4>
								<a href="#"><img alt="" src="<?php echo $html->url('/').'files/news/'.$html->getThumbnailName($article['News']['image']); ?>" class="wd-img-news" /></a>
								<p><?php echo $article['News']['description'] ?></p>
								<p><span><?php echo $article['News']['created'] ?></span></p>
								<a class="wd-view-detail" href="<?php echo $html->url('/news/news/view/'). $article['News']['alias'] .'/'. $category['NewsCategory']['alias']?>">Xem chi tiết</a>
							</li>
						<?php } ?>
						</ul>
					<?php } ?>
			<?php } ?>
			</div>	
		</div>
	</div>	
</div>